package cn.hk.dept.mapper;

import cn.hk.dept.domain.Dept;
import cn.hk.dept.domain.vo.DeptInfoVo;
import cn.hk.dept.domain.vo.DeptVo;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.ruoyi.common.annotation.DataSource;
import com.ruoyi.common.enums.DataSourceType;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * <p>
 * 部门表 Mapper 接口
 * </p>
 *
 * @author xu
 * @since 2023-03-09
 */
@DataSource(DataSourceType.KELIN)
public interface DeptMapper extends BaseMapper<Dept> {

     List<Dept> selectDeptListByAreaCodeAndDeptTypeAndIsOpen(@Param("areaCode")  String areaCode);

     Dept selectOneById(@Param("deptId") Long deptId);


    List<DeptInfoVo> selectDeptByPId(@Param("deptId")Long deptId);

    Dept selectOneByDeptId(@Param("deptId")Long deptId);

    List<DeptVo> selectDeptVoListByVid(@Param("areaCode")String areaCode,@Param("vaccinesId")Long vaccinesId);

    List<DeptVo> selectDeptVoListByAreaCode(@Param("areaCode")String areaCode);

    List<DeptVo> selectDeptVoListByDeptIdAndVid(@Param("deptId")Long deptId,@Param("vid") Long vid);
}
